<?php
define('ENVIRONMENT', 'development');
define('ROOT_PATH', __DIR__);
define('LIB_PATH', __DIR__ . '/Lib');
define('APP_PATH', __DIR__ . '/App');
define('SERVICE_PATH', __DIR__ . '/Service');
define('VENDOR_PATH', __DIR__ . '/vendor');
define('SELF', pathinfo(__FILE__, PATHINFO_BASENAME));


define('App_Name', 'Web');


// Register autoload
spl_autoload_register(function($class) {
    $classFile = ROOT_PATH . '/' . str_replace('\\', '/', $class) . '.class.php';
    if (is_file($classFile)) {
        require_once $classFile;
    }
});


$class = $argv['1'];

$classFile = LIB_PATH . "/QueueHandle/{$class}.class.php";

include "{$classFile}";
$className = '\Lib\\QueueHandle\\' . $class;


$obj = new $className();

$obj->execute($class);